package com.example.springbooteasycode.utils.tree;

import lombok.Data;

import java.io.Serializable;
import java.util.List;

/**
 * 设备分类表(CommunityDeviceType)表 Vo
 *
 * @author makejava
 * @since 2024-10-31 15:09:13
 **/
public class CommunityDeviceTypeTreeVO implements Serializable {

    private static final long serialVersionUID = 1L;


    /**
     * 自增主键
     */
    private Long id;

    /**
     * 设备分类编号
     */
    private String deviceTypeCode;

    /**
     * 小区编号
     */
    private String communityId;

    /**
     * 市code
     */
    private String cityCode;

    /**
     * 操作商户id
     */
    private String operateStoreId;

    /**
     * 设备分类名称
     */
    private String name;

    /**
     * 上级编号
     */
    private String parentCode;

    /**
     * 根节点编号
     */
    private String rootCode;

    /**
     * 结构排序
     */
    private Integer sort;

    /**
     * 是否叶子节点 0-是 1-否
     */
    private String hasLeaf;

    /**
     * 层级：T1,T2,T3
     */
    private Integer layer;

    /**
     * 设备分类类型：1.设施设备与房组
     */
    private String type;

    /**
     * 结构路径,采用#分割
     */
    private String treePath;

    /**
     * 是否系统默认 0.否 1.是
     */
    private String systemDefault;

    /**
     * 子节点
     */
    private List<CommunityDeviceTypeTreeVO> children;



    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getDeviceTypeCode() {
        return deviceTypeCode;
    }

    public void setDeviceTypeCode(String deviceTypeCode) {
        this.deviceTypeCode = deviceTypeCode;
    }

    public String getCommunityId() {
        return communityId;
    }

    public void setCommunityId(String communityId) {
        this.communityId = communityId;
    }

    public String getCityCode() {
        return cityCode;
    }

    public void setCityCode(String cityCode) {
        this.cityCode = cityCode;
    }

    public String getOperateStoreId() {
        return operateStoreId;
    }

    public void setOperateStoreId(String operateStoreId) {
        this.operateStoreId = operateStoreId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getParentCode() {
        return parentCode;
    }

    public void setParentCode(String parentCode) {
        this.parentCode = parentCode;
    }

    public String getRootCode() {
        return rootCode;
    }

    public void setRootCode(String rootCode) {
        this.rootCode = rootCode;
    }

    public Integer getSort() {
        return sort;
    }

    public void setSort(Integer sort) {
        this.sort = sort;
    }

    public String getHasLeaf() {
        return hasLeaf;
    }

    public void setHasLeaf(String hasLeaf) {
        this.hasLeaf = hasLeaf;
    }

    public Integer getLayer() {
        return layer;
    }

    public void setLayer(Integer layer) {
        this.layer = layer;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getTreePath() {
        return treePath;
    }

    public void setTreePath(String treePath) {
        this.treePath = treePath;
    }

    public String getSystemDefault() {
        return systemDefault;
    }

    public void setSystemDefault(String systemDefault) {
        this.systemDefault = systemDefault;
    }

    public List<CommunityDeviceTypeTreeVO> getChildren() {
        return children;
    }

    public void setChildren(List<CommunityDeviceTypeTreeVO> children) {
        this.children = children;
    }

    public CommunityDeviceTypeTreeVO(Long id, String deviceTypeCode, String communityId,
                                     String cityCode, String operateStoreId,
                                     String name, String parentCode, String rootCode,
                                     Integer sort, String hasLeaf, Integer layer,
                                     String type, String treePath, String systemDefault,
                                     List<CommunityDeviceTypeTreeVO> children) {
        this.id = id;
        this.deviceTypeCode = deviceTypeCode;
        this.communityId = communityId;
        this.cityCode = cityCode;
        this.operateStoreId = operateStoreId;
        this.name = name;
        this.parentCode = parentCode;
        this.rootCode = rootCode;
        this.sort = sort;
        this.hasLeaf = hasLeaf;
        this.layer = layer;
        this.type = type;
        this.treePath = treePath;
        this.systemDefault = systemDefault;
        this.children = children;
    }

    @Override
    public String toString() {
        return "CommunityDeviceTypeTreeVO{" +
                "id=" + id +
                ", deviceTypeCode='" + deviceTypeCode + '\'' +
                ", communityId='" + communityId + '\'' +
                ", cityCode='" + cityCode + '\'' +
                ", operateStoreId='" + operateStoreId + '\'' +
                ", name='" + name + '\'' +
                ", parentCode='" + parentCode + '\'' +
                ", rootCode='" + rootCode + '\'' +
                ", sort=" + sort +
                ", hasLeaf='" + hasLeaf + '\'' +
                ", layer=" + layer +
                ", type='" + type + '\'' +
                ", treePath='" + treePath + '\'' +
                ", systemDefault='" + systemDefault + '\'' +
                ", children=" + children +
                '}';
    }
}
